#include<iostream>
using namespace std;
const int N = 3e5 + 10;
int arr[N];
int n, q;
int main()
{
	cin >> n >> q;
	for (int i = 1; i <= n; i++) {
		scanf("%d", &arr[i]);
	}
	while (q--) {
		int op, l, r;
		scanf("%d%d%d", &op, &l, &r);
		if (op == 1) {
			arr[l] = r;
		}
		else {
			bool flag = 0;
			for (int i = l + 1; i <= r; i++) {
				if (arr[i] < arr[i - 1]) {
					flag = 1;
					break;
				}
			}
			if (!flag) {
				printf("Yes\n");
			}
			else {
				printf("No\n");
			}
		}
	}
	return 0;
}